<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">


    <title>浏览器</title>

    <link rel="shortcut icon" href="favicon.ico">
    <link href="css/bootstrap.min.css?v=3.3.5" rel="stylesheet">
    <link href="css/font-awesome.min.css?v=4.4.0" rel="stylesheet">
    <link href="css/plugins/sweetalert/sweetalert.css" rel="stylesheet">
    <!-- Morris -->
    <link href="css/plugins/morris/morris-0.4.3.min.css" rel="stylesheet">

    <!-- Gritter -->
    <link href="js/plugins/gritter/jquery.gritter.css" rel="stylesheet">

    <link href="css/animate.min.css" rel="stylesheet">
    <link href="css/style.min.css?v=4.0.0" rel="stylesheet">
    <link href="css/plugins/bootstrap-table/bootstrap-table.min.css" rel="stylesheet">
    <link rel="stylesheet" href="css/plugins/selectpicker/bootstrap-select.min.css">
    <base target="_blank">

</head>

<body class="gray-bg">
<div class="row  border-bottom white-bg dashboard-header">
    <div class="col-md-12">
        <div class="col-md-5">
            <select id="channelName" name="channelName" class="selectpicker" data-style="btn-info"
                    title="请选择Channel">
            </select>
        </div>
        <div class="col-md-5">
        </div>
        <div class="col-md-2">
            <!--<div class="col-sm-12">-->
            <button type="button" id="enableButton" class="btn btn-info btn-md" onclick="refreshPage()">
                <span class="glyphicon glyphicon-refresh"></span> 刷新
            </button>
            <!--</div>-->
            <button type="button" id="testBut" class="btn btn-info btn-md" onclick="infoChain()">
                <span class="glyphicon glyphicon-th"></span> chain详情
            </button>
        </div>
    </div>

</div>
<div class="wrapper wrapper-content">
    <div class="row">
        <!--<div class="col-sm-3">-->
        <div class="col-sm-3">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <span class="label label-info pull-right">正常</span>
                    <h5>Peer</h5>
                </div>
                <div class="ibox-content">
                    <h1 class="no-margins" id="peerNums">0</h1>
                    <!--<div class="stat-percent font-bold text-info"> <i class="fa fa-level-up"></i>-->
                    <!--</div>-->
                    <!--<small>新订单</small>-->
                </div>
            </div>
        </div>
        <div class="col-sm-3">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <span class="label label-info pull-right">正常</span>
                    <h5>Block</h5>
                </div>
                <div class="ibox-content">
                    <h1 class="no-margins" id="blockNums">0</h1>
                </div>
            </div>
        </div>
        <div class="col-sm-3">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <span class="label label-primary pull-right">正常</span>
                    <h5>Transaction</h5>
                </div>
                <div class="ibox-content">
                    <h1 class="no-margins" id="txNums">0</h1>
                </div>
            </div>
        </div>
        <div class="col-sm-3">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <span class="label label-danger pull-right">正常</span>
                    <h5>ChainCode</h5>
                </div>
                <div class="ibox-content">
                    <h1 class="no-margins" id="chaincodeNums">0</h1>
                    <!--<div class="stat-percent font-bold text-danger"> <i class="fa fa-level-down"></i>-->
                    <!--</div>-->
                    <!--<small>12月</small>-->
                </div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-sm-3">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>Block列表</h5>
                    <div class="ibox-tools">
                        <a class="collapse-link">
                            <i class="fa fa-chevron-up"></i>
                        </a>
                        <a class="close-link">
                            <i class="fa fa-times"></i>
                        </a>
                    </div>
                </div>
                <div class="ibox-content">
                    <table id="blockList" data-mobile-responsive="true" class="table table-no-bordered">
                        <thead>
                        <tr>
                            <th data-field="blockNum">
                                block编号
                            </th>
                            <th data-field="txCount">
                                交易数量
                            </th>
                        </tr>
                        </thead>
                    </table>
                </div>
            </div>
        </div>

        <div class="col-sm-9">

            <div class="row">
                <div class="col-sm-7">
                    <div class="ibox float-e-margins">
                        <div class="ibox-title">
                            <span id="currentBlockNum" class="label label-info pull-right">0</span>
                            <span>  </span>
                            <button id="detailBolckBtn" type="button" class="btn btn-xs btn-primary pull-right" onclick="getblockDetail()">详情
                            </button>
                            <h5>Block信息</h5>
                        </div>
                        <div class="ibox-content">
                            <form class="form-horizontal">

                                <div class="form-group">
                                    <!--class="col-sm-1 control-label"-->
                                    <label for="currentBlockNumber">Number: </label>
                                    <div class="col-sm-1">
                                    </div>
                                    <div class="col-sm-11">
                                        <button id="currentBlockNumber" type="button" class="btn btn-active"
                                                readonly></button>
                                        <div class="col-sm-1">
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label for="currentBlockHash">Hash:</label>
                                    <div class="col-sm-1">
                                    </div>
                                    <div class="col-sm-11">
                                        <button id="currentBlockHash" type="button" class="btn btn-info"
                                                readonly></button>
                                        <div class="col-sm-1">
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label for="preBlockHash">PreBlockHash:</label>
                                    <div class="col-sm-1">
                                    </div>
                                    <div class="col-sm-11">
                                        <button id="preBlockHash" type="button" class="btn btn-info" readonly></button>
                                        <div class="col-sm-1">
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label for="transactions">Transactions:</label>
                                    <div class="col-sm-1">
                                    </div>
                                    <div class="col-sm-11">
                                        <button id="transactions" type="button" class="btn btn-info"
                                                readonly></button>
                                        <div class="col-sm-1">
                                        </div>
                                    </div>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>
                <div class="col-sm-5">
                    <div class="ibox float-e-margins">
                        <div class="ibox-title">
                            <span id="belongBlockNum" class="label label-info pull-right">0</span>
                            <h5>Transaction信息</h5>
                        </div>
                        <div class="ibox-content">
                            <form class="form-horizontal">
                                <div class="form-group">
                                    <label for="txId" class="col-sm-2 control-label">txId: </label>
                                    <div class="col-sm-10">
                                        <button id="txId" type="button" class="btn btn-primary"></button>
                                        <!--<input type="email" class="form-control" id="inputEmail3" placeholder="Email">-->
                                    </div>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-sm-12">
                    <div class="ibox float-e-margins">
                        <div class="ibox-title">
                            <h5>Peer节点列表</h5>
                            <div class="ibox-tools">
                                <a class="collapse-link">
                                    <i class="fa fa-chevron-up"></i>
                                </a>
                                <a class="close-link">
                                    <i class="fa fa-times"></i>
                                </a>
                            </div>
                        </div>
                        <div class="ibox-content">
                            <table id="peerListTable" data-mobile-responsive="true" class="table table-no-bordered">
                                <thead>
                                <tr>
                                    <th data-field="peerId">
                                        节点ID
                                    </th>
                                    <th data-field="peerName">
                                        节点名称
                                    </th>
                                    <th data-field="hostAddress">
                                        节点地址
                                    </th>
                                    <th data-field="port">
                                        端口
                                    </th>
                                    <th data-field="eventPort">
                                        事件端口
                                    </th>
                                    <th data-field="tlsFlag">
                                        TLS状态
                                    </th>
                                </tr>
                                </thead>
                            </table>
                            <!--<table class="table table-hover no-margins">-->
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
<div class="modal inmodal fade" id="chain" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog modal-lg" style="width: 1080px;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span
                        class="sr-only">Close</span></button>
                <h4 class="modal-title">Chain信息</h4>
                <!--<small class="font-bold"></small>-->
                <div class="tabs-container">
                    <ul class="nav nav-tabs">
                        <li class="active"><a data-toggle="tab" href="#tab-1" aria-expanded="true">Detail</a>
                        </li>
                    </ul>
                    <div class="tab-content">
                        <div id="chainctab-1" class="tab-pane active">
                            <div class="panel-body">
                                <textarea id="chaincResult" name="chaincResult" class="form-control" rows="25"
                                          readonly></textarea>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-white" data-dismiss="modal">关闭</button>
            </div>
        </div>
    </div>
</div>
<div class="modal inmodal fade" id="blockInfo" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog modal-lg" style="width: 1080px;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span
                        class="sr-only">Close</span></button>
                <h4 class="modal-title">Block详情信息</h4>
                <!--<small class="font-bold"></small>-->
                <div class="tabs-container">
                    <ul class="nav nav-tabs">
                        <li class="active"><a data-toggle="tab" href="#tab-1" aria-expanded="true">Detail</a>
                        </li>
                        <li class=""><a data-toggle="tab" href="#tab-2" aria-expanded="false">Transaction</a>
                        </li>
                    </ul>
                    <div class="tab-content">
                        <div id="tab-1" class="tab-pane active">
                            <div class="panel-body">
                                <textarea id="blockDetail" name="blockDetail" class="form-control" rows="25" readonly></textarea>
                            </div>
                        </div>
                        <div id="tab-2" class="tab-pane">
                            <div class="panel-body">
                                <textarea id="txDetail" name="blockDetail" class="form-control" rows="25" readonly></textarea>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-white" data-dismiss="modal">关闭</button>
            </div>
        </div>
    </div>
</div>

<script src="js/jquery.min.js?v=2.1.4"></script>
<script src="js/bootstrap.min.js?v=3.3.5"></script>
<script src="js/plugins/bootstrap-table/bootstrap-table.min.js"></script>
<script src="js/plugins/bootstrap-table/bootstrap-table-mobile.min.js"></script>
<script src="js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script>
<script src="js/content.min.js?v=1.0.0"></script>
<script src="js/plugins/jquery-ui/jquery-ui.min.js"></script>
<script src="js/app/browser.js"></script>
<script src="js/plugins/sweetalert/sweetalert.min.js"></script>
<script src="js/plugins/selectpicker/bootstrap-select.min.js"></script>
<script src="js/plugins/selectpicker/i18n/defaults-zh_CN.min.js"></script>
</body>

</html>